package io.renren.modules.base.service.impl;

import io.renren.common.utils.RandomId;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

import io.renren.modules.base.dao.BasePhaseInfoDao;
import io.renren.modules.base.entity.BasePhaseInfoEntity;
import io.renren.modules.base.service.BasePhaseInfoService;


@Service("basePhaseInfoService")
public class BasePhaseInfoServiceImpl implements BasePhaseInfoService {
    @Autowired
    private BasePhaseInfoDao basePhaseInfoDao;

    @Override
    public BasePhaseInfoEntity queryObject(String id) {
        return basePhaseInfoDao.queryObject(id);
    }

    @Override
    public List<BasePhaseInfoEntity> queryList(Map<String, Object> map) {
        return basePhaseInfoDao.queryList(map);
    }

    @Override
    public int queryTotal(Map<String, Object> map) {
        return basePhaseInfoDao.queryTotal(map);
    }

    @Override
    public void save(BasePhaseInfoEntity basePhaseInfo) {
        basePhaseInfo.setId(RandomId.createId() + "");
        basePhaseInfoDao.save(basePhaseInfo);
    }

    @Override
    public void update(BasePhaseInfoEntity basePhaseInfo) {
        basePhaseInfoDao.update(basePhaseInfo);
    }

    @Override
    public void delete(String id) {
        basePhaseInfoDao.delete(id);
    }

    @Override
    public void deleteBatch(String[] ids) {
        basePhaseInfoDao.deleteBatch(ids);
    }

    @Override
    public List<BasePhaseInfoEntity> query() {

        return basePhaseInfoDao.query();
    }

    @Override
    public List<BasePhaseInfoEntity> allList() {
        return basePhaseInfoDao.allList();
    }

}
